Game-Action-Join-Card-Game names a function, with lambda list (ACTION):
Start playing a card game.
{ c: "gameAction", d: { action: "joinCardGame", playerP: [ true | false ], cardTable: UUID } }
Playing cards on a card table uses a special camera view to show the table top, and a pop-over layer to show the cards in the local player's hand.
Up to 4 players can join the game. Each player gets a side of the card table. See also TOOTSVILLE GAME-ACTION-PART-CARD-GAME.
The deck of cards can be 52 cards or have the 2 jokers for 54 in total. See TOOTSVILLE GAME-ACTION-CARD-GAME-SHUFFLE.
Players can draw from the deck (TOOTSVILLE GAME-ACTION-CARD-GAME-DRAW), deal cards to other players (TOOTSVILLE GAME-ACTION-CARD-GAME-DEAL), and place cards on the table face-up or face-down (TOOTSVILLE GAME-ACTION-CARD-GAME-PLAY), pick up cards from the table (TOOTSVILLE GAME-ACTION-CARD-GAME-TAKE), or move cards around on the table (TOOTSVILLE GAME-ACTION-CARD-GAME-MOVE) or in your hand (TOOTSVILLE GAME-ACTION-CARD-GAME-ARRANGE).
There are no particular rules of any card game enforced. Players are free to do whatever they like with the cards.
The ACTION passed references a card table. If that card table already has 4 players, this player can only become an observer. Otherwise, the player can choose to play or to observe.
The structure of ACTION includes these keys:
Attempting to join a card game as a fifth player will result in an error.
{ from: "gameAction", action: "joinCardGame", status: false, error: USER-ERROR-MESSAGE }
The user error message will be something suitable for display to the user to explain why they were refused joining the game.
On success, the player receives a datagram such as
{ from: "gameAction", action: "joinCardGame", status: true }
The player is then able to issue other gameAction packets as described in the preceding overview.
WRITEME
WRITEME
Defined in file src/infinity/game-actions.lisp.